Search Results

Search found 10177 results on 408 pages for 'thumbs db'.

Page 145/408 | < Previous Page | 141 142 143 144 145 146 147 148 149 150 151 152  | Next Page >

  • How to structure a Visual Studio project for the data access layer

    - by Akk
    I currently have a project that uses various DB access technologies mainly for showcasing or for demos. Currently we have: Namespace App.Data (App.Data.dll) Folder NHibernate Folder EntityFramework Folder LinqToSql The above structure is ok as we only use Sql Server as the DB. But going forward we will be including Oracle, MySql etc. So what would be a better structure with this in mind? I thought about: Namespace App.Data.SqlServer (App.Data.SqlServer.dll) Folder NHibernate Folder EntityFramework Folder LinqToSql Or would it just be better to have separate assemblies for each database and access technology?: Namespace App.Data.SqlServer.NHibernate (App.Data.SqlServer.NHibernate.dll) Namespace App.Data.SqlServer.EntityFramework(App.Data.SqlServer.EntityFramework.dll) Namespace App.Data.Oracle.NHibernate (App.Data.Oracle.NHibernate.dll) Namespace App.Data.MySql.NHibernate (App.Data.MySql.Oracle.dll)

    Read the article

  • SQL Server db_owner

    - by andrew007
    Hi, in my SQL2008 I have a user which is in the "db_datareader", "db_datawriter" and "db_ddladmin" DB roles, however when he tries to modify a table with SSMS he receives a message saying: You are not logged in as the database owner or system administrator. You might not be able to save changes to tables that you do not own. Of course, I would like to avoid such message, but until now I did find the way... Therefore, I try to modify the user by adding him to the "db_owner" role, and of course I do not have the message above. My question is: Is it possible to keep the user in the "db_owner" role, but deny some actions like alter user or ? I try "alter any user" securable on DB level, but it does not work... THANKS!

    Read the article

  • Sqlite database entries pass to array list?

    - by Rjay Guillermo Baltazar
    This is my code in getting the question into SQLite Database . I want to pass the questions into array list ? is it possible to my code ? Thanks for your help . public String getquestions() { // TODO Auto-generated method stub String[] sqlSelect = { "0 _id", "question", "answer" }; String sqlTables = "mytables"; SQLiteDatabase db = getWritableDatabase(); SQLiteQueryBuilder qb = new SQLiteQueryBuilder(); qb.setTables(sqlTables); String result = ""; c = qb.query(db, sqlSelect, null, null, null, null, null); int id = c.getColumnIndex(ID); int question = c.getColumnIndex(ROW1); int answer = c.getColumnIndex(ROW2); c.moveToFirst(); result = result + c.getString(question) + c.getString(count); return result; }

    Read the article

  • File created using MODE_WORLD_READABLE not getting sent as attachment by email

    - by Dheeraj
    I created the SQLite DB using the following code: context.openOrCreateDatabase(dbName, Context.MODE_WORLD_READABLE, null); And tried to send it as attachment by email using the following code: Intent emailIntent = new Intent(android.content.Intent.ACTION_SEND) .setType("message/rfc822") .putExtra(android.content.Intent.EXTRA_STREAM, Uri.fromFile(getDatabasePath(dbName))); startActivity(Intent.createChooser(emailIntent, null)); This opens the GMail compose activity with the attachment icon. But the recipient did not receive the attachment. This has been asked before. But it looks like there is no solution other than to copy the db file to SD card. My question then is: What is the use of the MODE_WORLD_READABLE flag if another app like GMail is unable to read the file?

    Read the article

  • How to write following MongoDB query in C# Driver?

    - by user3043457
    I wrote the exact query I need in Mongo console, but I'm having trouble rewriting it in C# driver. Here's a sample of the document, it's simple dictionary: { "_id" : ObjectId("539716bc101c588f941e2c27"), "_t" : "DictionaryDocument", "CsvSeparator" : ",", "SelectedAccounts" : "0", ... } Here's the query: db.settings.find({"SelectedAccounts" :{$exists:true}},{"SelectedAccounts":1, "_id":0} ) Now, I got the first part, Find with exists working, but how to write the second parameter in C# driver? I'd just like a single string as a result, not entire document. Here's C# code I got so far: _collection.FindOneAs(typeof(DictionaryDocument), Query.Exists(key)); key in this case is "SelectedAccounts". I'd like the query to filter and return only the data I need, I don't want to return all the results and search on the C# side. EDIT: I wouldn't mind if _id was passed back, but I don't need it. So only this part would work if it could be converted in C#: db.settings.find({"SelectedAccounts" :{$exists:true}},{"SelectedAccounts":1} )

    Read the article

  • choose append to existing backup instead of overwrite

    - by aron
    Hello, I have a database and I made it's first backup 2 days ago. Then yesterday I spent an entire adding new records. This morning I ran a backup, (but I selected append to existing backup set) as pictured below. I just ran a restore and I found that it wiped out all my data from yesterday and it restored it from the backup of 2 days ago. Not the version from this mornings backup. I zipped this backup file to be safe. I changed some data in the DB, Then I ran the back up again, but this time I selected "overwrite all existing backup sets" Now when I restore the db it's seems to restore the data from the backup correctly. I think I learned a lesson here, correctly if I'm wrong My questions is, Did I lose an entire day of work? I still have this morning's backup .bak file safe in a zip. Is there anyway I can restore is with the right data?

    Read the article

  • Serving images from Amazon S3 in PHP application

    - by luckytaxi
    So it just occurred to me that once I upload profile pics to S3, I have to figure out a way to keep track of the files. For example, if "susan" uploads 3 profile pics, I need to recall those 3 pictures and display it on her profile page if someone views her page. With that said, would the following work? User uploads picture from form Save file information (filename, user info, etc...) into DB and reference URL from S3 Upload photos to S3 When displaying pictures, I'll query the DB for the info and display the images from S3 accordingly.

    Read the article

  • Javascript eval limits

    - by user117701
    Is there a limit to javascript's eval, like in lenght? I'm trying to build an app where you can store JS code in the DB, which you can later load and eval in order to execute it, but i'm reaching a limit. First of all, the code has to all be in one line. Any multiline statements are not executed. Next, i'm reaching a limit in length (i guess). If i execute the code manually, it works, but put that same code in the db, load it via ajax, and try to execute it, and it fails. Any ideas why?

    Read the article

  • PHP Code- How to check duplicate entries in Mysql Database

    - by yash bhavnani
    Hi guys, I am working on Google checkout API notification URL. I want to apply a check in my php code which will see if transaction ID present in transaction table of my DB, it will exit not process. I am struggling into applying here. Can somebody help? I want to check if trasaction ID exists in table of DB it will exit, it will not process: *case "new-order-notification": $sql = "update transactions set remote_trans_id=\"".$_REQUEST["google-order-number"]."\", updated=now() where id=".$_REQUEST["shopping-cart_items_item-1_merchant-item-id"]." "; execute($sql, $conn); break;* Regards

    Read the article

  • How do I create a safe local development environment?

    - by docgnome
    I'm currently doing web development with another developer on a centralized development server. In the past this has worked alright, as we have two separate projects we are working on and rarely conflict. Now, however, we are adding a third (possible) developer into the mix. This is clearly going to create problems with other developers changes affecting my work and vice versa. To solve this problem, I'm thinking the best solution would be to create a virtual machine to distribute between the developers for local use. The problem I have is when it comes to the database. Given that we all develop on laptops, simply keeping a local copy of the live data is plain stupid. I've considered sanitizing the data, but I can't really figure out how to replace the real data, with data that would be representative of what people actually enter with out repeating the same information over and over again, e.g. everyone's address becomes 123 Testing Lane, Test Town, WA, 99999 or something. Is this really something to be concerned about? Are there tools to help with this sort of thing? I'm using MySQL. Ideally, if I sanitized the db it should be done from a script that I can run regularly. If I do this I'd also need a way to reduce the size of the db itself. (I figure I could select all the records created after x and whack them and all the records in corresponding tables out so that isn't really a big deal.) The second solution I've thought of is to encrypt the hard drive of the vm, but I'm unsure of how practical this is in terms of speed and also in the event of a lost/stolen laptop. If I do this, should the vm hard drive file itself be encrypted or should it be encrypted in the vm? (I'm assuming the latter as it would be portable and doesn't require the devs to have any sort of encryption capability on their OS of choice.) The third is to create a copy of the database for each developer on our development server that they are then responsible to keep the schema in sync with the canonical db by means of migration scripts or what have you. This solution seems to be the simplest but doesn't really scale as more developers are added. How do you deal with this problem?

    Read the article

  • Using WCF to expose underlying process

    - by Steven
    I have a server application that spins up and monitors about 8 separate processes that gather data from different systems. The server app then runs some calculations over the aggregated data and stores it in a db. Simple stuff. I now have a requirement to modify the process so that it no longer saves data to the db but rather exposes it directly to clients via WCF. That's cool, I've used WCF a fair bit but I'm struggling a little with it for some reason. Basically my plan is to HOST the WCF service in my application and have calls redirect into the internals of my existing application but I can figure out how to do that without getting the WCF class to encapsulate the existing app. I want the service to inside my current app, not become it. Any suggestions?

    Read the article

  • Rake migration aborted

    - by user2537714
    I'm running Ruby 2.0.0 and I installed it correctly. Just loaded up a gem 'devise' and as I tried to migrate my database changes, it wouldn't work: $ rake db:migrate rake aborted! attr_accessible is extracted out of Rails into a gem. Please use new recommended protection model for params(strong_parameters) or add protected_attributes to your Gemfile to use old one. Then, following another Stackoverflow post, they recommended installing Bundler. I did that successfully and got this: $ bundle exec rake db:migrate rake aborted! attr_accessible is extracted out of Rails into a gem. Please use new recommended protection model for params(strong_parameters) or add protected_attributes to your Gemfile to use old one. Is anyone up to the challenge to help?

    Read the article

  • Drupal node reference

    - by Nikunj Kotecha
    I am using two content types - test_parent & test_child In test_child there are two fields, both of type datetime And in test_parent there are two fields, week_no & 7 node references I am using node_save to save a new node. After saving a node of parent type, and then saving the node of child type, i want to update the node it into the parent type. I have completed creation of both nodes from code, and also i am able to update nid in parent type from code. The problem is, the change in db is getting reflected in db but not on drupal node view. Even if i edit the node from drupal, it's showing -none- selected in node reference. Please help.

    Read the article

  • Using IPrinciple.Identity.Name as a key in a dataBase to identify user's rows.

    - by bplus
    I'm writing a small intranet app that uses Windows Authentication and Asp.Net MVC. I need to store various bits of data in a db against each user. As far as I can tell the IPrinciple object does not seem to have something like a unique id. So I was thinking I could just use User.Identity.Name as a unique value to identify rows in my db. Is this a bad idea? Is there an alternative to this approach? Thanks for any help.

    Read the article

  • app_label in an abstract Django model

    - by rayan
    Hi all, I'm trying to get an abstract model working in Django and I hit a brick wall trying to set the related_name per the recommendation here: http://docs.djangoproject.com/en/dev/topics/db/models/#be-careful-with-related-name This is what my abstract model looks like: class CommonModel(models.Model): created_on = models.DateTimeField(editable=False) creared_by = models.ForeignKey(User, related_name="%(app_label)s_%(class)s_created", editable=False) updated_on = models.DateTimeField(editable=False) updated_by = models.ForeignKey(User, related_name="%(app_label)s_%(class)s_updated", editable=False) def save(self): if not self.id: self.created_on = datetime.now() self.created_by = user.id self.updated_on = datetime.now() self.updated_by = user.id super(CommonModel, self).save() class Meta: abstract = True My common model is in [project_root]/models.py. It is the parent object of this model, which is located in an app called Feedback [project_root]/feedback/models.py: from django.db import models from mediasharks.models import CommonModel class Feedback(CommonModel): message = models.CharField(max_length=255) request_uri = models.CharField(max_length=255) domain = models.CharField(max_length=255) feedback_type = models.IntegerField() Basically I'm trying to set up a common model so that I'll always be able to tell when and by whom database entries were created. When I run "python manage.py validate" I get this error message: KeyError: 'app_label' Am I missing something here?

    Read the article

  • FlockDB - What is it? And best cases for it uses.

    - by Guru
    Just came across FlockDB graph database. Details at github /flockDB. Twitter claims it uses FlockDB for the following: Twitter runs FlockDB on a large cluster of machines. we use it to store social graphs (who follows whom, who blocks whom) and secondary indices at twitter. At first glance, setup and trying it doesn't look straight forward. Have anyone already used it / setup this? If so, please answer the following general queries. What kind of applications is it better suited for? (Twitter claims it is simple and very rough, it remains to see what it meant though) How is FlockDB better than other graph db / noSQL db. Have you setup FlockDB, used it for a application? Early advices any? Note: I am evaluating the FlockDB and other graph databases mainly for learning them. Perhaps, I will build an application for that.

    Read the article

  • Unable to read values from object returned from ActiveRecord.find

    - by Venki
    I make the following call to the DB. @patientRegistration = PatientRegistration.find(:all, :conditions=["name = '#{patientName}'"]) Search for patient registration based on a given name. I get a valid @patientRegistration object.When I invoke @patientRegistration.inspect it prints correctly all the values for the object in the DB. But when I try to read a particular attribute (Say id or name) by doing the following: @patientRegistration.id or @patientRegistration.name. I get invalid values. Either its blank or some junk values. I dont understand how inspect is able to retrieve all the values correctly but reading individual attributes gives invalid values. Thanks

    Read the article

  • How to perform a join with CodeIgniter's Active Record class on a multicolumn key?

    - by Scott Southworth
    I've been able to make this code work using CodeIgniter's db->query as follows: $sql = 'SELECT mapping_code,zone_name,installation_name FROM installations,appearances,zones WHERE installations.installation_id = zones.installation_fk_id AND appearances.installation_fk_id = installations.installation_id AND appearances.zone_fk_id = zones.zone_id AND appearances.barcode = ? '; return $this->db->query($sql,array($barcode)); The 'appearances' table throws a 'not unique table' error if I try this using the Active Record class. I need to join appearances on both the zone and installations tables. How can I do this?

    Read the article

  • Seeking free ODBC database optimization tool for non-experts

    - by mawg
    I'm a database n00b and am reading as many books as I can. I have been given responsibility for an ODBC tool where the databases were designed by a hardware engineer with some VB experience - which made him a s/w guru in the small firm at that time. Things are running slowly and I suspect that the db could have been designed better. I hope to learn enough to use Explain/Describe, etc maybe add some indices, but, in the meantime, is there any free for commercial use tool which can examine an ODBC database and suggest improvements. I'm just talking about db schema here, but maybe I should also be looking at optimizing Selects with Joins? Is there a tool for that? ODBC compliant.

    Read the article

  • Why is rails setting ":null => false" on all my columns in schema.rb?

    - by ryeguy
    Even if I never specify :null => false in my migrations that initially add columns to tables, rails still generates code in schema.rb that specifies the columns as having :null => false. Why is this? If I develop on my box, and then use rake db:schema:load on my production box, I'm going to get very different behavior! Edit: Even if I delete schema.rb and run rake db:schema:dump, it still puts :null => false on the new schema even if it isn't defined like that in the actual database. It seems it can't tell whether or not a column is marked as allowing nulls. I'm using SQLite if that helps.

    Read the article

  • Hibernate Auto-Increment not working

    - by dharga
    I have a column in my DB that is set with Identity(1,1) and I can't get hibernate annotations to work for it. I get errors when I try to create a new record. In my entity I have the following. @GeneratedValue(strategy=GenerationType.IDENTITY, generator="native") @Column(name="SeqNo", unique=true, nullable=false) BigDecimal seqNo; But when I try to add a new record I get the following error. Cannot insert explicit value for identity column in table 'MemberSelectedOptions' when IDENTITY_INSERT is set to OFF. I don't want to set IDENTIY_INSERT to ON because I want the identity column in the db to manage the values. The SQL that is run is the following; where you can clearly see the insert. insert into dbo.MemberSelectedOptions (OptionStatusCd, EffectiveDate, TermDate, SelectionStatusDate, SysLstUpdtUserId, SysLstTrxDtm, SourceApplication, GroupId, MemberId, OptionId, SeqNo) values (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) What am I missing?

    Read the article

  • Cheap shared windows hosting

    - by Elangovan
    Hi I have recently purchased a domain from go daddy, now I am looking for a cheap windows hosting. Following are my requirements Shared Windows hosting Should be cheap in price Should have at least one SQL server Db and one mysql db. Should support atleast asp.net 3.5 and php Will be good if it has support for asp.net mvc (no problem even if it is not available also) Should be able to install third party blog sites. Bandwidth, total space and performance are not very important. Silverlight is also an added advantage (no problem even if it is not available also). There should be no advertisement or banner added by the hosting company in the site.

    Read the article

  • MVC framework for huge JEE application

    - by chaKa
    Which MVC-framework is the best option (performance/ease of development) for a web application, that will have + 2 million visits per week. Basically the site is a search engine,but also there will be large amounts of xml parsing, and high db traffic. We are using Java, over Jboss 4.2.3x, with PG as DB, and Solr for the searches. We were thinking on code JSPs with taglibs, and Servlets, but we were feeling like there would be a better alternative, which don't know yet, as we are starting on the Java Web applications world. Any opinions, and shares of your experience will be appreciated! Thanks in advance!

    Read the article

  • Best place to store large amounts of session data

    - by audiopleb
    I'm building an application that needs to store and re-use large amounts of data per session. So for example, the user selects a large list of list items (say 2000 or significantly more) which have a numeric value as their key then they save that selection and go off to another page, do something else and then come back to the original page and need to load their selections into that page. What is the quickest and most efficient way of storing and reusing that data? In a text file saved with the session id? In a temp db table? In the session data itself (db sessions so size isn't a limit) using a serialised string or using gzcompress or gzencode? Any advice or insight would be great! Thank you!!!!

    Read the article

  • Problem of import DBI module - Complication Failed in require

    - by Winnie
    Hi All, I have a problem when I use the DBI module in scritp .pm. please help thanks you package CC; use DBI; use strict; use Alias; my $dbFile = 'XXXXXXXX.db'; my $db = DBI-connect("dbi:SQLite:$dbFile","","", {RaiseError =1, AutoCommit = 1})or "Unable to connect: $DBI::errstr\n"; use Alias qw(attr); our ($CURRENTOFFSET,@LANGUAGE); sub new { my $that = shift; my $class = ref($that)|| $that; my $self = { CURRENTOFFSET= undef, LANGUAGE = [] }; bless($self, $class); return $self; }

    Read the article

< Previous Page | 141 142 143 144 145 146 147 148 149 150 151 152  | Next Page >