Hello, i have some scripts and in the database tabel i have set the dato to int(25) and timestamp
i have a create topic script and then i create a topic it insert the date and time in the timestamp tabel (dato).
but somehow my comment script will not insert the time :S and its the same stuff i use :S.
here is my script
if(isset($_PO...
This SQL statement works if I run it from my Oracle client (SQL Developer):
insert into Person (Name) select 'Bob' from dual
It also works if I issue it via Spring JDBC, without using a KeyHolder:
final PreparedStatementCreator psc = new PreparedStatementCreator() {
@Override
public PreparedStatement createPreparedStatement(...
Alright we are quite sure the Elmah has become too big. Apparently the database is sitting at 17GB because of this. Were were getting timeout errors accessing /elmah first and now there are errors inserting data into it - hence exceptions are being thrown by the application.
I just wanted to confirm can INSERT timeouts happen - or does ...
[Edit: forget this post - I'm not sure what NHibernate is doing, but it's not doing what I just said it's doing. Please ignore.]
I have a 'parent' class in the object graph called Case.
Here's a snapshot of Case:
public class Case
{
public virtual Person Deceased {get;set;}
public virtual IList Executors { get; set; }
public Ca...
Hi all
Let's say you have two classes, Person and Address.
Person has a reference to Address like this:
public class Person
{
public virtual Address Residence {get;set;}
}
Address has an override of .Equals which determines whether two Address instances represent the same physical address (by comparing postcode and first line, say...
I have a Case class which exposes a Person object as follows:
public class Case
{
public virtual Person Deceased {get;set;}
}
I have a PersonalAsset class which also exposes a Person:
public class PersonalAsset
{
public virtual Person Owner {get;set;}
}
Assuming I write the following code within an ISession:
Case case = new Ca...
Hi all,
This should be a fairly straightforward question, but I haven't been able to find a solid answer online. I'm trying to insert multiple rows into the same table, but with only one statement. The most popular I've seen online is the following, but I've read that it only works with SQL Server 2008:
INSERT INTO Table (Name, Locatio...
Hi,
as the title said, I have a problem between java and mysql
The mysql DB, tables, and columns are utf8_unicode_ci.
I have an application that took some input from an xml, then compose the query...
public String [] saveField(String xmltag, String lang){
NodeList nodo = this.doc.getElementsByTagName(xmltag);
String [] pos = ...
Hi,
I'm trying to insert an element at a specific point within my file, then save that file out. However, I can't seem to get it right. My XML layout is like this:
<?xml version="1.0" encoding="utf-8"?>
<Settings>
<Items />
<Users />
</Settings>
This is my current code:
XDocument xd = XDocument.Load(@"C:\test.xml...
How can I get the Id back to the object when I'm using the AddMany function with SubSonic SimpleRepository. All my objects still get Id=0 when after using it.
SimpleRepository repository = new SimpleRepository(ConnectionStringName);
repository.AddMany<T>(insertList);
When looking at the source I can see that:
public void AddMany<T>(I...
On my ASP.NET MVC application I'm running a couple of inserts at once that can insert 10000 or more lines and update a few others. This process is taking a long time but I can't escape the insert because that's exactly what I was asked to do.
Right now I'm running Sql Server Profiler and it takes almost 20 minutes to insert this bunch of...
Hi,
I have created a method that will insert any exceptions thrown into a table on "ExceptionLog" on MySql server.
ExceptionLog Table format
idExceptionLog int (AI)
User (varchar 45)
ErrorMessage (varchart 4000)
The problem is i keep getting the following error. Does anyone know why?
The SqlParameterCollection only
accepts non-...
Hi,
I have 2 tables loginInfo and UserInfo. LoginInfo Stores username and passwords while userinfo stores other user details such as Address,postalcode,phone etc.
I insert values into loginInfo first and if successful I enter the userInfo details. If exception occurs while entering details into userInfo i delete the loginInfo details....
Can anyone please advise where i have gone wrong with the following method / stored proceedure? I keep getting the following error...
**
> Input string was not in a correct
**
This is the Stored proceedure i using and the method.
-- --------------------------------------------------------------------------------
-- Routine DDL
-- ...
if I have two tables: files(id, owner) and share(file_id, user), where owner and user would be primary IDs from a theoretical user table, how can I insert an entry into share only if the user doing the sharing owns that file?
This is a stripped down example, so I'll just use a literal for the one doing the share operation -- normally th...
I'd like to insert a row into table A, but only if another row in table B exists. For example something like this...
IF EXISTS (SELECT * FROM B WHERE id=1)
INSERT INTO A
(id, value1, value2)
VALUES (1, 'foo', 'bar')
However that doesn't work. What will?
...
when I run this sql:
insert into table1(ID,Name) values ('10','Saeed');
it seems that the record has been inserted, and if I read the table using (select * from table1) it shows me the inserted record, but after closing the program, it disappears.
it's the code:
string constr="Data Source=.\\SQLEXPRESS;AttachDbFilename=|DataDirector...
Hello, I'm trying to post a serialized form to a sumbit.php file, in turn, will then insert into a MySQL database; however, the last input which is hidden, is not getting inserted into the database, though the rest are.
Here's some snippet examples of what I've got thus far which is not working:
HTML
<form method="post" ...
Hey guys,
I need to insert an image wherever the user clicks on a specified element (another image), and for it to sit in front of that image. Can this be done in javascript? If not, with what?
Thanks
...
I can add an extra field to the registration. What I need to know is what step do I need to take to then grab that input and insert it into the user table of drupal. The code below is in my module this adds just a field to the form, but when its submitted it doesnt do anything with the data.
function perscriptions_user($op, &$edit, &$ac...