I'm working on this record insert/delete I'm not sure what the syntax is to perform the query.
I have a user model and an event model. I have created a joining table called Personal that stores the user_id, and event_id of any events that the users like.
I created an "Add" method in my events controller so whenever someone clicks it r...
In the cakePHP project I'm building, I want to insert a defined number of identical records. These will serve as placeholders records that will have additional data added later. Each record will insert the IDs taken from two belongs_to relationships as well as two other string values.
What I want to do is be able to enter a value for th...
I'm having some trouble using MySQLi to insert values into a database. I don't get any errors, but the values being inserted are not correct at all. One of the TEXT fields is always empty, and the other one always has the value "ý". The INT field always contains the value 50396416. I am using utf8_general_ci.
CREATE TABLE events (
i...
Yes, I understand tuples are immutable but the situation is such that I need to insert an extra value into each tuple. So one of the items is the amount, I need to add a new item next to it in a different currency, like so:
('Product', '500.00', '1200.00')
Possible?
Thanks!
...
I have the following map structure: map < pair < int,int >, object* > and I wish to insert into it. How would I do it since I am trying to insert a pair and an object and I must make a pair out of this. Should I create a new pair using make_pair() out of the pair and object that I have? If so, could you please let me know how to do this?...
Hey guys, new to WPF and really struggling with 'the right way' to do things...
public void Save(CompanyContact entityToSave)
{
try
{
var saveEntity = (from cc in db.CompanyContacts
where cc.CompanyContactId == entityToSave.CompanyContactId
select cc).SingleOrDefault();
if (saveEntity == null)
{
/...
I have the field:
APP_DATE (smalldatetime)
I'm doing this query:
INSERT INTO table (TYPE, CODE, APP_DATE, DATE) VALUES ('APP', '123', '02/10/2010 12.30', GETDATE())
It fails:
Msg 296, Level 16, State 3, Line 1
Conversion from datatype char to smalldatetime generated a value not between the interval of valid values.
Instruction has...
I am trying to insert into a DB with has the following columns: ID (autonumber), BonderIdentifier (text), Username (text), Login (date), Logout (date).
BonderIdentifier, Username, Login is the PK.
Here is what I do:
Public Function submitNewToDB(ByVal sessionData As BonderSession) As Boolean
Dim cn As OleDbConnection
Dim cmd...
hi all, i have a post with a LOT of variables, and I was wondering if there was some way of inserting the information into mysql dynamically, rather than typing it all out manually, as the post variables change depending on what the user selects.
...
i created the database like this
db.execSQL("CREATE TABLE "+TABLE_NAME+" ("
+_ID+" INTEGER PRIMARY KEY AUTOINCREMENT,"
+ TITLE+" TEXT UNIQUE,"
+ PUBLISHED+" DATETIME,"
+ CONTENT+" TEXT,"
+ RATERS+" TEXT,"
+ VIEWCOUNT+" TEXT,"
+ THUMBNAIL+" TEXT,"
+ FAVCOUNT+" TEXT,"
+ FAVSTAT+" INTEGER,"
+ LI...
I use LinqDataSource in my web pages and I want to handle Business rules in Changed event of properties and also OnValidate method of an entity.
I can delete other entities in partial delete also, I can upload other entities in partial Insert and Update methos but I can't Insert entites in partial update or delete methods.
Example : I ha...
Hello,
I'm using an XSLT stylesheet (by Antennahouse) to convert XHTML to an XSL-FO file. I defined a blank line in my XHTML file as 2 consecutive HTML BR tags. Now there is no native support for a blank line in the XSL-FO format. I want to work around this limitation by adding a height to the fo:block that the stylesheet inserts for a ...
On a users profile, there is a comment box that enables other users to post comments on their profile. I am now working on a dynamic comment area that has a changing text box depending on if A. you are looking at your own profile B. looking at someone elses profile C. not signed in at all.
I am trying to implement "updates" now when you...
Hi, I'm learning LINQ, and am having trouble with inserting and updating in one go. I have a StatusReport table (School, Customer, Time), where School is the primary key, and a Service table (School, ServiceName, State, and Version), where School is a foreign key, and School + ServiceName is the primary key.
Here's my update code:
pub...
I wish to insert into a c++ vector at a known position. I know the c++ library has an insert() function that takes a position and the object to insert but the position type is an iterator. I wish to insert into the vector like I would insert into an array, using a specific index.
...
I have two tables kinda like this:
// Person.Details Table:
PersonID int [PK] | EmployeeCreatorID int [FK] | FirstName varchar | OtherInfo...
// Employee.Details Table:
EmployeeID int [PK] | PersonID int [FK] | IsAdmin bit | OtherInfo...
Each table is related to the other:
[Employee.Details.PersonID]===>[Person.Details.PersonID] AND...
I have a WPF question.
I have 2 textboxes and an image control in a WPF Form.
The image control has an image in it.
I want to insert the contents of each of the text boxes and the image in the 3 separate columns in an SQL database.
The text boxes feed into varchar columns while the image itself is loaded into a column with datatype ima...
I'm trying to insert a row in my Google spreadsheet. While other functions like counting rows, columns etc work fine; inserting a row gives me 'Namespace Error'.
An exception of type DOMException was thrown, but did not get caught during the execution of the request. You will find information provided by the exception along with a stac...
Hello, World!
I've got iBrowser plugin and what i need is to change HTML code for the img tag when I click insert button. Actually i want to have the opportunity to insert alternative code (user could check a certain checkbox, or click another button, say "Insert link" next to "insert").
Now the code looks like this
<img title="xxx" s...
Hi,
I'm building a system for updating large amounts of data through various CSV feeds. Normally I would just loop though each row in the feed, do a select query to check if the item already exists and insert/update an item depending if it exists or not.
I feel this method isn't very scalable and could hammer the server on larger fee...