Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
P

PrashantJ

@PrashantJ
About
Posts
75
Topics
49
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • How to access the page values in a webservice?
    P PrashantJ

    Hi, I want to pass some values to the webservice writern in C# from my ASP page. In the ASP page, I am using the Yahoo UI functions to make a webservice call like this Append("oACDS = new YAHOO.widget.DS_XHR(\"AC1.aspx\", [\"Table\", \"Order\"]);\n"); .... Response.Write(Copy()); I am able to get the value keyed into the text box ... I am using this call in the webservice string query = Request.QueryString["query"]; So similarly I want to pass more values from the asp page to webservice, can anybody pls let me know how can i do this? Thanks in advance

    ASP.NET question csharp database design tutorial

  • Can an ASP.Net Control be used in old asp page?
    P PrashantJ

    Okay thanks.

    ASP.NET question csharp asp-net sysadmin

  • Can an ASP.Net Control be used in old asp page?
    P PrashantJ

    Hi, I have the legacy asp code in which I will now have to plug in some ASP.Net server controls to make one text box AJAX enabled. So my question is can we have a ASP.Net control in the old asp page(.asp not .aspx) My asp code looks something like this. To make this Text box AJAX enabled, I am writing code like this Append(""); SO can I use asp:XXX in my .asp page? Plus if I have the Atlas dll in my project can I also use atlas:XXX here.. Thanks in advance

    ASP.NET question csharp asp-net sysadmin

  • Using webservice call in Yahoo UI Lib
    P PrashantJ

    Hi, I want to use the autocomplete feature from Yahoo UI Library with a webservice call to the database in my ASP.Net application. (I dont want to use ATLAS-AJAX) I want to achieve something like this (as given below) but instead of using a static array i want to connect to the db using webservice in my ASP.NET application

    // A JavaScript Array DataSource var statesArray = [ "Alabama", "Alaska", "Arizona", "Arkansas", "California", "Colorado", "Connecticut", "Delaware", "Florida" // Entire array not shown ]; var myDataSource1 = new YAHOO.widget.DS_JSArray(statesArray); var oAutoComp = new YAHOO.widget.AutoComplete("myInput","myContainer", myDataSource1); I have this code below which uses the Atlas-ajax feature to perform the autocomplete. But want to add the missing code using YUI syntax using webservice (BLOCK 2) BLOCK 1 BLOCK 2

    Find a product:

    oACDS = new YAHOO.widget.???????? ????? Does anybody have any links/pointers to the Yahoo UI objects and usage of webservices. So ideally BLOCK 1 and BLOCK 2 should return values from the db using ProductService.asmx Thanks in advance. PJ

    ASP.NET database csharp javascript asp-net design

  • using sp_MSForEachTable to delete data with a where clause [modified]
    P PrashantJ

    Hi All, I wanted to use the undocumented SP sp_MSForEachTable to selectively delete data from tables. So in short i want to achieve something like this using sp_MSForEachTable. delete from TableName where Date = '2007-01-03' I looked at various queries on the internet using sp_MSForEachTable, but was not able to find out the usage of sp_MSForEachTable with a "Where" clause, so if anybody has the query or links request to post it here. All that I found was to delete all data from all the tables in the db. I tried using the @whereand option like this, but the got an error saying Invalid column: SomeDate. I have this column in all the tables in that database. I did a quick check looping thro all the tables using cursors and that works fine. EXEC sp_MSForEachTable @command1='DELETE FROM ?' ,@whereand='and SomeDate = "2007-01-15"' Thanks. PJ -- modified at 14:39 Monday 15th January, 2007

    Database database sharepoint help question

  • Script/tool to update schema of my database when the latest_schema script is provided
    P PrashantJ

    Hi All, I want to write a script/tool which would update the schema of the existing database (in SQL Server 2005) i.e Add/drop a table, column, constraint etc. on a ongoing basis. The input to my tool would be the latest_schema script which creates the database with all the latest tables, columns, constraints etc. So the tool that I am going to write should perform a schema-diff with my db Vs the script provided and add/drop the tables, cols, constraints on my database. I have a couple of solutions in my mind but feel that they are not very efficient. 1. Create a new database running the provided script, write a stored procedure to loop thro all the tables to figure out the diff between the existing db and the current db and update the current db: Problem here is my current db has data and lots of constraints, which might pose a problem. 2. Use some third party tools to generate the sync script and execute it against my current db but I am not sure about the free tools available out there. Can somebody please provide me some guidelines/tips on how to go ahead about this. Thanks in advance. PJ

    Database database tools sql-server visual-studio sysadmin

  • How to debug a storeprocedure in sql server 2000 and 2005?
    P PrashantJ

    In SQL Server 2000, you can right click the stored procedure and debug but for SS2005 I guess you can debug only thro Visual Studio 2005.

    Database database question sharepoint sql-server sysadmin

  • Script/tool to update schema of my database when the latest_schema script is provided
    P PrashantJ

    Hi All, I want to write a script/tool which would update the schema of the existing database (in SQL Server 2005) i.e Add/drop a table, column, constraint etc. on a ongoing basis. The input to my tool would be the latest_schema script which creates the database with all the latest tables, columns, constraints etc. So the tool that I am going to write should perform a schema-diff with my db Vs the script provided and add/drop the tables, cols, constraints on my database. I have a couple of solutions in my mind but feel that they are not very efficient. 1. Create a new database running the provided script, write a stored procedure to loop thro all the tables to figure out the diff between the existing db and the current db and update the current db: Problem here is my current db has data and lots of constraints, which might pose a problem. 2. Use some third party tools to generate the sync script and execute it against my current db but I am not sure about the free tools available out there. Can somebody please provide me some guidelines/tips on how to go ahead about this. Thanks in advance. PJ

    Database database tools sql-server visual-studio sysadmin

  • Date/time functions in SQL Server 2005
    P PrashantJ

    Hi All, I am looking for the functions in SQL server which would return me the mid day, last day of the month given the current date and the param. I would appreciate if you could point me to some related links. I have written some SQLs to do this but looks very ugly with lots of code. Input will be some date and period. Output will be the Till ending date interval1 and Till ending date interval2 If period(1) = weekly then the Till ending date = end of the current week (Sun) - I assume a week begins on Monday. If period(2) = bi-weekly then the Till ending date = end of the following week (Sun) If period(3) = semi-monthly & today <= 15th of the month then the Till ending date = 15th of the current month, otherwise Till ending date = end of month. If period(4) = monthly then the Till ending date = end of month For example: Input Some_date : 1-Jan-2006 Period Output Period Out1 Out2 1 8-Jan 15-Jan 2 15-Jan 29-Jan 3 15-Jan 31-Jan 4 31-Jan 28-Feb Thanks for the help.

    Database database sql-server sysadmin help tutorial

  • Any daylight saving related function in SQL Server 2005?
    P PrashantJ

    Hi, Is there any function in SQL server 2005 which takes the date/time and time zone as the parameters and returns whether the given date/time follows the daylight savings or not. I was looking to a function in SQL Server very similar to the WIN API GetTimeZoneInformation(). So the input: date/time, time zone Output: true/false (follows daylight savings/does not follow) Pls let me know. Thanks.

    Database database sql-server sysadmin json question

  • Any Windows API related to daylight saving available?
    P PrashantJ

    Okay Thanks

    System Admin json question

  • Any Windows API related to daylight saving available?
    P PrashantJ

    Hi, I was looking for an Windows API which would take the current date/time, local time zone and return true/false indicating whether the current time / time-zone is using daylight saving or not. If no API is available pls direct me to some useful links Thanks.

    System Admin json question

  • CLR Integration.
    P PrashantJ

    Hi, In my application I have various SQL stored procedures (In SQL Server 2005) and now I want to add the tracing feature. If turned on, then print some informational lines onto a file stating the control path and if turned off, do not write to the file. Is this possible by using the cool new feature "CLR Integration". If yes can anybody point me to some links. I have some basic knowledge of C# as well. Thanks,

    C# csharp database sql-server dotnet sysadmin

  • Determine max column length info using SqlDataAdapter, XmlDataDocument classes in C#
    P PrashantJ

    I had posted this question last friday, but havent found a solution yet, so posting it again in case somebody is aware of the solution. ** Original message ** Hello, This is my code which will convert the ADO resultset to XML in C#. I actually need the column type, column max length etc also in the xml, like the column type/length of id, loginuserid, deptid, wrkstnid etc. So I am not sure whether I need to pass some parameters to SqlDataAdapter class while executing the SQL command or the XmlDataDocument class has some methods which would print out the datatype and column length information in the XML. Looked at both the classes, didnt find any method, anybody has any ideas about this? Thanks DataSet ds = new DataSet(); SqlDataAdapter adapter = new SqlDataAdapter(cmd); adapter.Fill(ds); if (ds.Tables.Count>0) { _sBody = new StringBuilder("", _bodySize); //Get xml representation of the dataset XmlDataDocument srcXML = new XmlDataDocument(ds); srcXML.Save("c:\\XMLDocument.xml"); .... } 1tpmadmin11

    2sysadmin22

    ----------------------------------------------- ** Paul Brower's Reply ** Try this, (with 'ds' being your dataset) ds.WriteXml(@"c:\thedataset.xml",System.Data.XmlWriteMode.WriteSchema) ; That will write out all your xml with the schema. ----------------------------------------------- ** Question ** I actually want the max size of the column and I think that information is missing in the XML. The XML looks something like this. Max size of the column is used by the XSL to print the data. For datatypes like int, numeric, datetime I can manage the column lenght, problem arises only when its of type string, char etc It has the column name, type, minOccurs. I think the max size of the column is missing, do I need to try some other method, or any other argument? Thanks,

    C# xml database question csharp help

  • Determine datatype, column length info using SqlDataAdapter, XmlDataDocument classes in C#
    P PrashantJ

    Okay, I actually want the max size of the column and I think that information is missing in the XML. The XML looks something like this. Max size of the column is used by the XSL to print the data. For datatypes like int, numeric, datetime I can manage the column lenght, problem arises only when its of type string, char etc It has the column name, type, minOccurs. I think the max size of the column is missing, do I need to try some other method, or any other argument? Thanks, -- modified at 16:24 Friday 5th May, 2006

    C# csharp database xml question

  • Determine datatype, column length info using SqlDataAdapter, XmlDataDocument classes in C#
    P PrashantJ

    Hello, This is my code which will convert the ADO resultset to XML in C#. I actually need the column type, column max length etc also in the xml, like the column type/length of id, loginuserid, deptid, wrkstnid etc. So I am not sure whether I need to pass some parameters to SqlDataAdapter class while executing the SQL command or the XmlDataDocument class has some methods which would print out the datatype and column length information in the XML. Looked at both the classes, didnt find any method, anybody has any ideas about this? Thanks DataSet ds = new DataSet(); SqlDataAdapter adapter = new SqlDataAdapter(cmd); adapter.Fill(ds); if (ds.Tables.Count>0) { _sBody = new StringBuilder("", _bodySize); //Get xml representation of the dataset XmlDataDocument srcXML = new XmlDataDocument(ds); srcXML.Save("c:\\XMLDocument.xml"); .... } 1tpmadmin11

    2sysadmin22

    -- modified at 12:25 Friday 5th May, 2006

    C# csharp database xml question

  • A question in SQL Query
    P PrashantJ

    Hi, My query looks like this select distinct lh.id, od.storename FROM LPNHeader lh LEFT OUTER join LPNDetail ld on lh.Id = ld.LPNHdrId LEFT OUTER JOIN OrderDetail od on ld.OrderDtlId = od.Id INNER JOIN OrderShipmentLPN OSL ON LH.id = OSL.LPNHdrId INNER JOIN ShipmentHeader sh on sh.id = osl.shipmentHdrId WHERE sh.Id = 25 and the results are 346 SN1 347 SN1 347 SN2 348 SN2 348 SN3 349 NULL I want to finetune this query to return distinct lh.id's, like given below 346 SN1 347 SN1 348 SN2 349 NULL Tried distinct, group etc. I think that I am missing something, anybody any ideas. Thanks

    Database database question

  • Converting the XML form of resultset to string in C#
    P PrashantJ

    Okay I understand. I think the resultset is in the form of xml. I get the resultset by executing this int iRecs = cmd.ExecuteNonQuery(); So what can I pass to this call below? source = new XPathDocument(...) Thanks.

    C# database xml csharp help question

  • Converting the XML form of resultset to string in C#
    P PrashantJ

    Hi, In my C# application I am trying to execute a SQL query, transform the query results (using XSL) returned in a form of XML, and ultimately want the resutlset as a string in resultSetToAscii. I have started working on C# very recently, so I am sure that I am doing some silly mistake. Basically my code fails in the 3rd line here and the error desc is "Data at root level is invalid". Anybody any ideas? XPathDocument destination; XPathDocument source; source = new XPathDocument(new StringReader("//row")); destination = new XPathDocument(_xsl.Transform(source, null, (XmlResolver)null)); XPathNavigator nav = destination.CreateNavigator(); { XPathNodeIterator iterator = nav.Select("//row"); while (iterator.MoveNext()) { foreach (Field field in _destinationFields) { string data = ""; if (field.name != null) data = iterator.Current.GetAttribute(field.name, String.Empty); resultSetToAscii = data.PadRight(field.size, ' '); } } }

    C# database xml csharp help question

  • XML and XSL transform in C#
    P PrashantJ

    Hi, I would appreciate if somebody could post some links (or sample code) to transform a ADO resultset to string using XSL. Thanks.

    C# xml csharp
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups