I would like to create an application from a database schema using seam-gen, unfortunatly informix isn't supported out of the box.
Where can I add another db?
Hi,
I'm starting learning Ruby on Rails. So my application, like every Rails app, has three databases:
Development
Test
Production
And the question is: how do i switch from a db to another?
Thanks
I have some philosophical feeling that adding to an entity fields which doesn't mapped to the DB is a wrong way of solving problems.
But are there any concrete situations where using @Transient fields leads to implicit and hard fixing problems?
For example, is it possible that adding/removing 2nd level cache will break our app when there are @Transient fields in our entities?
Is it possible to override methids for db.Model in Google App Engine?
I want to declare beforeSave, afterSave methods, etc.. to create automatic tagging system.
I know there are hooks, but it seems to me a wrong way to solve this issue :)
Thanks!
I got table with next columns: Id, Name, Age, Class
I am trying to insert new row in db like this:
INSERT INTO MyTable (Name, Age, Class)
VALUES (@name, @age, @class)
And get an exeption:
"Index or primary key cannot contain a Null value."
The question is how to add a new row without knowing next primary Id, or maybe there is a way to get this Id from the table with the help of another query ?
I want this SQL query to be written in rails controller using find
select id,name from questions where id not in (select question_id from levels_questions where level_id=15)
How will I do this?I am using Rails framework and MySQL db
thanks in advance.
Hi all, i have searched Google and also searched Stack Overflow to no avail.
I am looking for a PHP / MySQL driven dynamic image slideshow. One similar to 'lightcyclers.com', i have information stored in the DB and i just want to display random or popular content etc.
I am also not interested in coding one myself as i am busy working on other features.
Any links or help would be much appreciated.
I am using mysql_fetch_assoc($query), one of the bit field returns out to be , which is supposedly to be true.
The problem is that I also need to output this to xml and it's an illegal xml character.
the charset for the db table is utf-8. why does this happen?
to create new a new databse file start sql server management studio express on db server and create it!
i would like to create a database using c# in my web application visual studio 08
is it possible?
as connection string has to have a name of database to connect, but i want to create one.
Hi
I am using two different databases for my project.
Oracle and apache derby and trying to use as much as possible ansi sql syntax supported by both of the databases.
I have a table with column amount_paid NUMERIC(26,2), in a table.
My old code which was using oracle db need to retrieve value in this format
SELECT LTRIM(TO_CHAR(amount_paid,'9,999,999,999,999.99')) .
How can i do this using ANSI sql syntax.
I'm looking for a Java ORM that works from database reflection - I need to just point it at a DB, and start being able to walk through the entire set of tables, etc.
Ideas?
Hi There,
we have a requirement to develop a webapp ,using C# in bussiness layer, sql server as DB,
and Flex as the UI . given this i want to know tips,tricks and pitfalls .
mainly WRT Design and deployment.
Thanks in Advance.
Deepak
is there an activerecord (any similar SQL-wrapper) for python? which is good for:
used in a server-side python script
light-weight
supports MySQL
what I need to do:
insert (filename, file size, file md5, the file itself) into (string, int, string, BLOB) columns
if the same file (checksum + filename) does not exist in db
thx
Ok, So I have to generate very complex reports from my DB.
If I am to do it with SQL the query themselves will be complex, and I will have to do some more manipulation on the results later, code level.
How do libraries like Jasper Reports/ Crystal Reports and friends save me time when developing such reports?
What will they give me?
I have some data in db,now i m making them to display in the front end so,i ii have a update button,if i click it the selected values to come to database
http://dpaste.com/hold/180761/
Thnx in advance.
Hi,
Is it possible for entering values into dropdown and saving that values to DB? If yes please help me by giving the code for that. Thanks in advance
In MongoDB, I have a document with a field called "ClockInTime" that was imported from CSV as a string.
What does an appropriate db.ClockTime.update() statement look like to convert these text based values to a date datatype?
I am taking a text file from user and then posting that file back to the browser using ajax storing the content in db and then showing the content back to user page using Jquery post response.
Now i want to something like this..
Read the text file from the user computer using javascript. Display the content and when he submits the page I will save the values.
Hi,
I have a method which handles a set of records.This method,return true\false after processing.So,if all the records are processed(doing some db updates),will return true.Now,suppose after processing 1 record,some exception is thrown,should I write result=false(at the end of method result is returned) in catch block? And,allow processing of other records to be done?
Hi I am trying to make a simple search form that uses a startTime and endTime to specify a time range. The db has a datetime field time that is compared against.
So far when i try to use params[:startTime] in the controller I get an array of values which wont work with :conditions = ['time < ?', params[:endTime]]
Is there a simple solution to parse the form's datetime to SQL datetime?
I would like to set some values in the node before actually writing the data to the DB. I already have it working by modifying book_nodeapi but I would like to do it from outside the code, some _alter option that allows me to leave the module code untouched would be great.
Thanks
Hi all, We need to find a way to programatically *link all the tables* in a SQL Server database to an access db. We will be invoking this access database from a program that uses .net/SQL Server 2008.
While invoking the application we would like to add the linked tables so that the users can just run the reports/modules from access without having to worry about linking the tables. Is there a way we can do this?
Thanks!
So, MongoDB defaults to "AND" when finding records. For example:
db.users.find({age: {'$gte': 30}, {'$lte': 40}});
The above query finds users = 30 AND <= 40 years old.
How would I find users <= 30 OR = 40 years old?
Could anyone help me please in JQuery?
I have two tables on my site leftTable and rightTable with same column names. The leftTable I fill up from a DB, but the rightTable it just contains some rows. What I would like to do is to not show (or remove) in the leftTable those rows which are exist in the rightTable!
I Tryed this:
$("#tableLeft tr").each(function ()
{if ($(this).find("td")[0].innerHTML == $("#tableRight tr").find("td")[0].innerHTML) {$(this).remove;}});
I want to use a database which name is stored in a variable. How do I do this?
I first thought this would work but it doesn't:
exec('use '+@db)
That will not change database context
Suggestions anyone?