Search Results

Search found 11778 results on 472 pages for 'mark ms smith'.

Page 82/472 | < Previous Page | 78 79 80 81 82 83 84 85 86 87 88 89  | Next Page >

  • Call stored proc using xml output from a table

    - by user263097
    Under a tight deadline and I know I can figure this out eventually but I don't have much time to do it on my own. I have a table that has columns for customer id and account number among many other additional columns. There could be many accounts for a single customer (Many rows with the same customer id but different account number). For each customer in the table I need to call a stored procedure and pass data from my table as xml in the following format. Notice that the xml is for all of the customers accounts. <Accounts> <Account> <AccountNumber>12345</AccountNumber> <AccountStatus>Open</AccountStatus> </Account> <Account> <AccountNumber>54321</AccountNumber> <AccountStatus>Closed</AccountStatus> </Account> </Accounts> So I guess I need help with 2 things. First, how to get the data in this xml format. I assuming I'll use some variation of FOR XML. The other thing is how do I group by customer id and then call a sproc for each customer id?

    Read the article

  • Access: Expression too complex to be evaluated

    - by user2502964
    I'm trying to sort out values from a database by the weekending date. The script I'm using functions on 6 of my 7 databases (they are all constructed identically). The 7th database doesn't function. I get the expression too complex error. any help figuring out why?? Here is my code: SELECT UPC_Test.Type, UPC_Test.[Model No], UPC_Test.[Model Desc], UPC_Test.[Serial No], Format(DateValue([UPC_Test].[Test Date]+7-Weekday([UPC_Test].[Test Date],0)),"m/d/yyyy") AS [Test Date], UPC_Test.Parameter, UPC_Test.[Failure Symptom], UPC_Test.[Repair Action], UPC_Test.[Factory Select], UPC_Test.[Test Station] FROM UPC_Test GROUP BY UPC_Test.Type, UPC_Test.[Model No], UPC_Test.[Model Desc], UPC_Test.[Serial No], Format(DateValue([UPC_Test].[Test Date]+7-Weekday([UPC_Test].[Test Date],0)),"m/d/yyyy"), UPC_Test.Parameter, UPC_Test.[Failure Symptom], UPC_Test.[Repair Action], UPC_Test.[Factory Select], UPC_Test.[Test Station] HAVING (((UPC_Test.Type)="Production") AND ((Format(DateValue([UPC_Test].[Test Date]+7-Weekday([UPC_Test].[Test Date],0)),"m/d/yyyy"))=[Enter]) AND ((UPC_Test.[Failure Symptom])<>"") AND ((UPC_Test.[Repair Action])<>"") AND ((UPC_Test.[Test Station])="UPC RF Test")) ORDER BY Format(DateValue([UPC_Test].[Test Date]+7-Weekday([UPC_Test].[Test Date],0)),"m/d/yyyy");

    Read the article

  • How to use value from primary accessdatasource control as parameter in select query for secondary ac

    - by weedave
    Hi, I'm trying to display all orders placed and I have a primary accessdatasource control that has a select query to get the customer information and the orderID. I want to use the orderID value from this first query as a parameter for the secondary accessdatasource control that selects the product information of the products in the order. In plain english, I want to:- select product info from product table where orderID = ? (where ? is the orderID value from the first query) I have tried the <%#Eval("OrderID")% but I get a "server tag not well formed" error, but I do get results returned when I just type the order ID in, but obviously every result (order) just contains the same product info... <asp:Repeater ID="Repeater1" runat="server" DataSourceID="AccessDataSource1"> <ItemTemplate> <asp:AccessDataSource ID="AccessDataSource2" runat="server" DataFile="~/App_Data/project.mdb" SelectCommand="SELECT orderDetails.OrderID, album.Artist, album.Album, album.Cost, album.ImageURL, orderDetails.Quantity, orderDetails.Total FROM (album INNER JOIN orderDetails ON album.AlbumID = orderDetails.AlbumID) WHERE (orderDetails.OrderID = ? )"> <SelectParameters> // Error is on this line <asp:Parameter Name="OrderID" DefaultValue="<%#Eval ("OrderID")%>" /> </SelectParameters> </asp:AccessDataSource> <div class="viewAllOrdersOrderArea"> <div class="viewAllOrdersOrderSummary"> <p><b>Order ID: </b><%#Eval("OrderID")%></p> <h4>Shipping Details</h4> <p><b>Shipping Address: </b><%#Eval("ShippingName")%>, <%#Eval("ShippingAddress")%>, <%#Eval("ShippingTown")%>, <%#Eval("ShippingPostcode")%></p> <h4>Payment Details</h4> <p><b>Cardholder's Address: </b><%#Eval("CardHolder")%>, <%#Eval("BillingAddress")%>, <%#Eval("BillingTown")%>, <%#Eval("BillingPostcode")%></p> <p><b>Payment Method: </b><%#Eval("CardType")%></p> <p><b>Card Number: </b><%#Eval("CardNumber")%></p> <p><b>Start Date: </b><%#Eval("StartDate")%>, Expiry Date: <%#Eval("ExpiryDate")%></p> <p><b>Security Digits: </b><%#Eval("SecurityDigits")%></p> <h4>Ordered items:</h4> <asp:Repeater ID="Repeater2" runat="server" DataSourceID="AccessDataSource2"> <ItemTemplate> <div style="display: block; float: left;"> <div class="viewAllOrdersProductImage"> <img width="70px" height="70px" alt="<%# Eval("Artist") %> - <%# Eval("Album") %>" src="assets/images/thumbs/<%# Eval("ImageURL") %>" /> </div> <div style="display:block; float:left; padding-top:15px; padding-right:20px;"><p><b><%# Eval("Artist") %> - <%# Eval("Album") %></b></p> <p>£<%# Eval("Cost") %> x <%# Eval("Quantity") %> = £<%#Eval("Total")%></p></div> </div> </ItemTemplate> </asp:Repeater> </div> </div> </ItemTemplate> </asp:Repeater>

    Read the article

  • SQL Query: Using IF statement in defining new field

    - by Tofig Hasanov
    I have a table with many fields and additionally several boolean fields (ex: BField1, BField2, BField3 etc.). I need to make a Select Query, which will select all fields except for boolean ones, and a new virtual field (ex: FirstTrueBool) whose value will equal to the name of the first TRUE Boolean Field. For ex: Say I have BField1 = False, BField2 = True, BField3 = true, BField4=false, in that case SQL Query should set [FirstTrueBool] to "BField2". Is that possible? Thank you in advance. P.S. I use Microsoft Access (MDB) Database and Jet Engine.

    Read the article

  • Calculate value from two field in third field

    - by terence6
    I'm trying to create a query, that will calculate sum of products on invoice. I have 3 tables : Product (with product's price) Invoice (with invoice id) Products on invoice (with invoice id, product id and number of particular products) So in my query I take invoice_id (from invoice), price (from product),number of products sold and invoice_id (from products on invoice) and calculate their product in fourth column. I know I sohuld use 'Totals' but how to achieve that ? Model:

    Read the article

  • why is ADODB inserting NULL values on update?

    - by every_answer_gets_a_point
    i have: With rs .AddNew ' create a new record ' add values to each field in the record .Fields("datapath") = dpath .Fields("analysistime") = "atime" .Fields("reporttime") = "rtime" .Fields("lastcalib") = "lcalib" .Fields("analystname") = "aname" .Fields("reportname") = "rname" .Fields("batchstate") = "bstate" .Fields("instrument") = "NA" .Update ' stores the new record End With when i check the database, it looks like it ONLY inserted the last field! has anyone encountered this problem?

    Read the article

  • Designing Relational Survey Questionnaires Database

    - by user1213055
    I'm trying to build a simple sql database for following access database. Currently there is no relationship and I just have two tables male and female with 6 sections in each form. How can I design it a better way so end user can connect to the database and analyze using STATA or SPSS ? I'm really confused whether I should create one table with all fields or break down into different tables. The database is specific to this study only so I'm not looking for a generic survey database where user can create surveys and capture them. Any feedback or suggestion is much appreciated.

    Read the article

  • Adding linked table to Access 2003 while keeping ODBC connection info in MDB

    - by webworm
    I have an Access 2003 database MDB where all of the tables exist as linked tables within SQL Server 2005. The MDB file contains all of the ODBC information that points to the correct SQL Server and log-on credentials (trusted connection). What I would like to do is add a new linked table to the MDB file however I am not sure how to go about specifying the ODBC connection information. When I try to add a new linked table I keep getting prompted to locate or create a DSN file. I don't want to have to create a new DSN entry on every machine, rather I would like all that information stored within the Access MDB file itself. In the existing database I can "hover" over the table names and see the ODBC connection info as a tool-tip. All I need to do is add another linked table using the same connection information. I do have access to the SQL Server where the tables are linked to,. I have already created the new table I wanted to add. I just need to find a way to link to it.

    Read the article

  • Why extremely occasionally will one of bof/eof be true for a new non-empty recordset

    - by jjb
    set recordsetname = databasename.openrecordset(SQLString) if recordsetname.bof <> true and recordsetname.eof <> true then 'do something end if 2 questions : the above test can evaluate to false incorrectly but only extremely rarely (I've had one lurking in my code and it failed today, I believe for the first time in 5 years of daily use-that's how I found it). Why very occasionally will one of bof/eof be true for a non-empty recordset. It seems so rare that I wonder why it occurs at all. Is this a foolproof replacement: if recordsetname.bof <> true or recordsetname.eof <> true then Edit to add details of code : Customers have orders, each order begins with a BeginOrder item and end with an EndOrder item and in between are the items in the order. The SQL is: ' ids are autoincrement long integers ' SQLString = "select * from Orders where type = OrderBegin or type = OrderEnd" Dim OrderOpen as Boolean OrderOpen = False Set rs = db.Openrecordset(SQLString) If rs.bof <> True And rs.eof <> True Then myrec.movelast If rs.fields("type").value = BeginOrder Then OrderOpen = True End If End If If OrderOpen F False Then 'code here to add new BeginOrder Item to Orders table ' End If ShowOrderHistory 'displays the customer's Order history ' In this case which looks this this BeginOrder Item a Item b ... Item n EndOrder BeginOrder Item a Item b ... Item n EndOrder BeginOrder Item a item b ... Item m BeginOrder <----should not be there as previous order still open

    Read the article

  • OpenArgs Problem in Access

    - by kkbondo
    I have a code like this: Dim strResponses As String strResponses = Forms!frmResponses.QstnID.OpenArgs If Len(strResponses) 0 Then Me![QstnID].DefaultValue = Me.OpenArgs End If When I run it, its gives error 438. Can someone help me to know where the error is?

    Read the article

  • What is a way to access .accdb files for reading and writing?

    - by JPJedi
    I have an Microsoft Access Database (.accdb) that stores information needed in an application. Is there a way to distribute my application with the access database without having the user have access installed or get the user to go and download and install the office runtime? The windows form application that uses the access database is developed in VB.net in Visual Studio 2008.

    Read the article

  • Comparing textbox value to database

    - by simon
    HI ! I would like to compare values from a textbox with data from a table. I tried this code but i got the error that the input string was in the wrong format! code: string connectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=save.mdb"; try { database = new OleDbConnection(connectionString); database.Open(); string queryString = "SELECT zivila.naziv,users.user_name FROM (obroki_save " + " LEFT JOIN zivila ON zivila.ID=obroki_save.ID_zivila) " + " LEFT JOIN users ON users.ID=obroki_save.ID_uporabnika " + " WHERE users.ID='" +Convert.ToInt16(id.iDTextBox.Text)+"'"; loadDataGrid(queryString); } catch (Exception ex) { MessageBox.Show(ex.Message); return; }

    Read the article

  • Batch Script [Loop through file names]

    - by Kyl3
    Hi, I would like a batch script to all the text documents in a folder. This is what I have managed so far @ECHO off title Test set dir1=C:\Users\Family\Desktop\Example :Start cls echo 1. test loop echo 2. Quit set /p choice=I choose (1,2): if %choice%==1 goto test if %choice%==2 exit :test cls echo running loop test FOR %%n in (%dir1% *.txt) DO echo %dir1%\%%n echo Done pause What I would like outputted is running loop test C:\Users\Family\Desktop\Example\doc 1.txt C:\Users\Family\Desktop\Example\doc 2.txt Done But I Get this running loop test C:\Users\Family\Desktop\Example\C:\Users\Family\Desktop\Example C:\Users\Family\Desktop\Example\doc 1.txt C:\Users\Family\Desktop\Example\doc 2.txt Done Thanks in advance Kyle

    Read the article

  • VBA Or .NET for working with Office?

    - by hosseinsinohe
    Hi All I want to develop and automate Office software like 'Microsoft Excel 2007' And 'Microsoft Word 2007'. But I do not know how to use VBA or use C#/.Net Framework to do so. What are the benefits of using VBA vs .Net framework? Which one should I focus on learning?

    Read the article

  • access: control source of textbox

    - by I__
    there is a form where a user enters a date in [Text4] when users clicks OK, the following code is run: DoCmd.OpenReport "All_Ones", acViewPreview the following is the control source of a textbox on the report [Forms]![By Number]![Text4] for some reason after the report is open, it just sayd #?nameor something like that, meaning that it is an invalid parameter. what am i doing wrong?

    Read the article

  • Use currently logged-in user in query

    - by Degan
    I am using VisualWebDeveloperExpress2008 with Access as the membership provider. I have some cases where I want users to edit their own data. This would involve a query where the UserId should equal the UserID of the user who is using the site. I am expecting to use WHERE UserId = ?, but I have not found out where to direct "?". The IDE gives several choices, but I am uncertain which to choose. This, while it looks promising does not work: <SelectParameters> <asp:ProfileParameter Name="UserID" PropertyName="UserId" Type="Int32" /> </SelectParameters> What is best to use for the Select Parameter?

    Read the article

  • convert function from Access SQL to T-SQL 2005

    - by Pace
    Can someone please convert this access sql function for me to work in t-sql 2005. I am tring to take the selling price minus the cost as one number. And divide that by the original selling price to produce a second number Thanks :) =IIf([Selling Price]=0,0,([Selling Price]-Nz([Cost]))/[Selling Price]) IIRC it should be something along the lines of; ISNULL((ISNULL([Selling Price],0) - ISNULL(Cost,0)),0) / ISNULL([Selling Price],0) AS Margin But here I am getting a divide by Zero error. any suggestions?

    Read the article

  • Creating Simple desktop database application

    - by KoolKabin
    Hi guys, I am here to write a small database application that will be running in desktop (offline mode). I am using MSAccess 2007 as my database file and trying to write code in vb.net. I used to write the code vb6 an usually had global variables for storing database connection and executing every query from that. I am trying to upgrade myself from vb6 to vb.net. do i need to read some more simple starter books also?

    Read the article

< Previous Page | 78 79 80 81 82 83 84 85 86 87 88 89  | Next Page >