I just want to create the model once, and then use it in any kind of database, without the need to modify the model.
What I should do with the data type ? I found there is numeric and other kind of data types. What does that correspond to in mysql or access ?
...
I'm creating a database that's going to contain various artists which can be tagged with several tags. It's a standard many-to-may relation and my database looks like this:
artist:
ID
name
tag:
ID
name
tagID:
tagID
artistID
Say I've got two tagIDs, X and Y. What I want to do is to find all the tags that have an artist in...
I need to programmatically (ADO.Net) copy records from a table in one database to a table in another database on a different server.
This is very similar to "How can I copy data records between two instances of an SQLServer database" except that I am not allowed to create a link to the destination server so the accepted answer to that qu...
Has anyone ever done row-level security in LLBLGenPro? If so, how?
...
Hi,
I've just installed a fresh copy of SQL 2008 Express. before I did anything I opened Management Studio and successfully connected using Window Authentication.
However I tried to run the following on the command line
"telnet localhost 1433" and got the error "Could not open connection to the host, on port 1433: Connect failed"
I c...
I have two mysql databases that have almost the same structure and representing the data of the same web app but one of them represents the current version and second one was made long time ago.
How can I create the database with both dumps inside but with old_ prefix for tables from the first and new_ prefix for tables from the second ...
I've got a query joining several tables and returning quite a few columns.
An indexed column of another table references the PK of one of these joined tables. Now I would like to add another column to the query that states if at least one row with that ID exists in the new table.
So if I have one of the old tables
ID
1
2
3
and th...
As a Java Developper using JPA/Hibernate, I am looking for a will help diff a database that has been generated by Hibernate with a production database.
I've already looked at LiquiBase's abilities LiquiBase which is quite nice... Unfortunlately it is plagued by some weird bugs:
Re-Create Foreign Keys for no reason
Re-Create Indexes fo...
I generate change scripts for my database to keep it under source control, and a strange thing happens every time:
I have a FlowFolder table, and clicking Generate Scripts creates the following two scripts:
dbo.FlowFolder.Table.sql:
USE [NC]
GO
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
SET ANSI_PADDING ON
GO
CREATE TABLE [dbo]....
This is driving me crazy. I have a library I source from multiple scripts, which contains the following function:
function lib_open_dataset([string] $sql) {
$ds = new-object "System.Data.DataSet"
$da = new-object "System.Data.SqlClient.SqlDataAdapter" ($sql, $_conn_string)
$record_count = $da.Fill($ds)
return $ds
}
T...
Is there a way I can generate a database schema from an erlang application like I can do with hibernate.
...
heya,
I think my understanding of Django's FK and admin is a bit faulty, so I'd value any input on how to model the below case.
Firstly, we have generic Address objects. Then, we have User's, who each have a UserProfile. Through this, Users belong to departments, as well as having addresses.
Departments themselves can also have multip...
Hello, newbie programmer here.
I have 3 tables namely product, category, and subcategory. I configured their relationships this way:
Product to Category: Many-to-many
Product to Subcategory: One-to-one
Subcategory to Category: Many-to-one
I added a subcategory_id column which is a foreign key in the product table (for mapping the prod...
Hi,
I have this method in my database class.and I want to get a part of data from a column which is "dateOfBirth" in MySQL table ,but I don't know why the list.size() is "0" but when i use System.out.println() in my code it will show just the first line of sql table ,although I have two rows!!!
my method:
public static int getBirthP...
Please help me in writing SWIG interace.
I want to open a database connection handle in C program. This handle must be passed to Perl, where I will use the Perl DB interface for interacting with the database. For security purpose we wanted to use this mechanism. I want to pass the database handle using SWIG interface.
Added:
We are ...
Hey, I am trying to make a password retrieval system on my site, and I am having problems updating the password reset field in my database. I have tried everything, but nothing seems to work.
This is my code so far:
$passwordreset = md5(mt_rand()) . md5(mt_rand()) . md5(mt_rand());
$con = mysql_connect("localhost","XXX","XXX");
if...
Hi all,
Just a quick question that no doubt someone out there will know the answer to.
I need to be able to do multiple insert/updates within a trigger. Every attempt ends with failure :(
DROP TRIGGER IF EXISTS `Insert_Article`//
CREATE TRIGGER `Insert_Article` AFTER INSERT ON `Article`
FOR EACH ROW insert into FullTextStore (`Table...
Hi,
I am new bee to Hibernate and trying out things.
One thing that seems to amuse all is how to connect to different databases?
I have two questions here
a) if in the same web app i need to connect to mysql and oracle how do i do it?
b) i am using mysql and have two databases test1 and test2, how to connect and retrieve data?
I have rea...
EDIT
I'm understand the table is a mess. I took over this project and am rewriting the PHP and making serious changes to the database. I am not asking how I should layout the database. I need to make a quick, temporary fix and am looking for a better way to write the query below.
END EDIT
Hi there!
So I have this query(below) this is ...
I'm working with an older Oracle database, and I feel there's likely a better way to go about unboxing the values I retrieve from the database.
Currently, I have a static class full of different type-specific methods:
public static int? Int(object o)
{
try
{
return (int?)Convert.ToInt32(o);
}
catch (Exception)
...