How mapping sharepoint list Columns to Sql server data table columns programaticlly
Hi ,
I have one Verification List in share Point ,in that list i have 10 columns.And we have sql server in that sql server we have one data table Verification_Table
in that table we have 25 column, my requirement is all list data move to sql data table[ what ever columns mapping to list--->data table that data store in data table reaming column is Null]
using grammatically not in BCS
Hello,
You can create SQL connection and use Datareader to read from SQL.Firs create a connection string and put this string in web application web.config file of your sharepoint site.
Now use below code to call your connectionstring in your webpart.
SqlConnection con = new SqlConnection(System.Configuration.ConfigurationManager.AppSettings["ConnectionString"]);
Here is link to read the data from SQL:
http://www.akadia.com/services/dotnet_data_reader.html
Here is one MSDN link to read SP list data:
http://msdn.microsoft.com/en-us/library/dd490727%28v=office.12%29.aspx
Let me know if you have any doubt
Hemendra:Yesterday is just a memory,Tomorrow we may never see
Please remember to mark the replies as answers if they help and unmark them if they provide no help
Similar Messages
-
I am using Excel source which uses Microsoft ACE 12.0 OLE DB provider, this only allows the first 255 columns to be imported and not the rest.
I need to export all the columns into the table .
Any pointers to this is greatly appreciatedIf you can use third-party solutions, check the commercial COZYROC Excel adapters:
Excel Connection Plus Manager
Excel Source Plus
Excel Destination Plus
Excel Task
The enhanced components can be used both under 32bit and 64bit modes and doesn't exhibit the 255 columns limitation.
SSIS Tasks Components Scripts Services | http://www.cozyroc.com/ -
Viewing SQL Server data(NTEXT column) to Oracle
Hi,
I m trying to connect Oracle 12c to MS SQL (Gateway)
HTRAPORU column is NTEXT type on MS SQL
SELECT T.HTRAPORUTEXT, T.HTRAPORU,
T.DURUMID, T.LABOZELNOT, T.SGTARIHSAAT, T.LABKABULTARIHI, T.CALISMABASLAMATARIHI,
T.CALISMABITISTARIHI, T.ONAYTARIHI, T.RAPORTARIHI, T.SUBEID, T.KILITLI,
T.MIND, T.MAXD, T.REFD, T.IPTAL, T.ACIL
FROM HTEST@ESKIDB T
WHERE HTETKIKKARTID=122477901
ORDER BY CASE WHEN BARKODNO IS NULL THEN 1 ELSE 0 END, BARKODNO;
I get a query error from my SQL Developer saying:
ORA-00904: "T"."HTRAPORU": invalid identifier
00904. 00000 - "%s: invalid identifier"
*Cause:
*Action:
Error at Line: 2 Column: 29
I tried to use, like "HTEST"@ESKIDB and "T.HTRAPORU" but Problem not resolved
Can anyone help me on this please?
Yasin PolatI Tried;
SELECT "Durumid" FROM htest@eskidb WHERE rownum= 1;
ORA-00904: "Durumid": invalid identifier
00904. 00000 - "%s: invalid identifier"
*Cause:
*Action:
Error at Line: 38 Column: 8
SELECT Durumid FROM htest@eskidb WHERE rownum= 1;
Normal Result
DURUMID
11
Info: on MSSQL DURUMID=Integer HTRAPORU=Ntext -
MAP Toolkit - How to use this MAP tool kit for all SQL Server inventory in new work enviornment
Hi Every one
Just joined to new job and planning to do Inventory for whole environment so I can get list of all SQL Server installed . I downloaded MAP tool kit just now. So looking for step by step information to use this for SQL Inventory. If anyone have documentation
or screen shot and can share would be great.
Also like to run It will be good to run this tool anytime or should run in night time when is less activity?
Hoe long generally takes for medium size environment where server count is about 30 ( Dev/Staging/Prod)
Also any scripts that will give detailed information would be great too..
Thank you
Please Mark As Answer if it is helpful. \\Aim To Inspire Rather to Teach A.ShahHi Logicinisde,
According to your description, since the issue regards Microsoft Assessment and Planning Solution Accelerator. I suggestion you post the question in the Solution Accelerators forums at
http://social.technet.microsoft.com/Forums/en-US/map/threads/ . It is appropriate and more experts will assist you.
The Microsoft Assessment and Planning (MAP) Toolkit is an agentless inventory, assessment, and reporting tool that can securely assess IT environments for various platform migrations. You can use MAP as part of a comprehensive process for planning and migrating
legacy database to SQL Server instances.
There is more information about how to use MAP Tool–Microsoft Assessment and Planning toolkit, you can review the following articles.
http://blogs.technet.com/b/meamcs/archive/2012/09/24/how-to-use-map-tool-microsoft-assessment-and-planning-toolkit.aspx
Microsoft Assessment and Planning Toolkit - Technical FAQ:
http://ochoco.blogspot.in/2009/02/microsoft-assessment-and-planning.html
Regards,
Sofiya Li
Sofiya Li
TechNet Community Support -
How to convert rows to columns in sql server 2008
How to convert rows to columns in sql server 2008 using the GROUP BY function? (only one query allowed)
Lookup the Pivot transformation. From BOL:
The Pivot transformation makes a normalized data set into a less normalized
but more compact version by pivoting the input data on a column value. For
example, a normalized Orders data set that lists customer name, product, and quantity purchased typically has multiple rows for any customer who purchased multiple products, with each row for that customer showing order
details for a different product. By pivoting the data set on the product column, the Pivot transformation can output a data set with a
single row per customer. That single row lists all the purchases by the customer, with the product names shown as column names, and the quantity shown as a value in the product column. Because not every customer purchases every product, many columns may contain
null values.
When a dataset is pivoted, input columns perform different roles in the pivoting process. A column can participate in the following ways:
The column is passed through unchanged to the output. Because many input rows
can result only in one output row, the transformation copies only the first
input value for the column.
The column acts as the key or part of the key that identifies a set of
records.
The column defines the pivot. The values in this column are associated with
columns in the pivoted dataset.
The column contains values that are placed in the columns that the pivot
creates.
Paul -
Desc doesn't show datetime columns from SQl Server
Hi Everyone,
I have working db link to sql server using hsodbc:
Oracle 10.2 on AIX using freetds odbc driver version 0.82.
I can access tables on sql server but oracle sees only varchars and numerics columns in a table.
Is there a way to select datetime columns from sql server using hsodbc?when hsodbc does not show a certain data type it is commonly related to the fact that HSODBC doesn't support the related ODBC data type.
In general you have a data type in your SQL Server which is mapped to an ODBC data type by the ODBC driver. HSODBC then maps the ODBC data type to an Oracle equivalent and when the ODBC data type isn't supported by HSODBC it just drops it from the select list.
So for a root cause analysis an ODBC trace is required to determine the mapping of the FreeTDS ODBC driver.
With this info we can then compare the mapping documented in the HSODBC manual and if the ODBC data type isn't listed as a supported data type you then need to cast the data type on the source side to a different data type (for example varchar/char).
So please post the ODBC trace and I'll have a look.
- Klaus
Edited by: kgronau on Apr 2, 2013 12:50 PM
BTW, here the link to the HSODBC docu:
http://docs.oracle.com/cd/B19306_01/server.102/b14232.pdf
Oracle® Database
Heterogeneous Connectivity Administrator's Guide
10g Release 2 (10.2)
B14232-01
B.1 Mapping ANSI Data Types to Oracle Data Types Through an ODBC
Interface -
How to store/display images with SQL Server 2000
Hi everybody, I'm totally new to ColdFusion, and creating a
sample project, where a user would enter in a person's info and
upload a picture of that person. I trying to get my app to save
that image to SQL Server database and then to display that pic.
Currently, it "seems" that I'm able to save to SQL server (my table
saves user info but all values in my photo column says
<binary>-I don't know if that is correct), but I can't seem
to get image and display it on my cf page. I have pasted portions
of my code below.
I've been hammering away at this but no luck, so Any comments
are very well appreciated, example code would be great!
Thank you so much,
noijet
# 1.) I have a 'User Info Entry' page that submits to page
#2:
<cfform...>
<input name="fileToUpload" id="fileToUpload" type="file"
size="64"/>
</cfform>
# 2.) This page does the actual saving, this doesn't output
any errors but am I saving the image to SQL server correctly? I
have no idea really how to save images to database, so please
advise or possibly provide example code. Afterwards, it goes to
page #3 to display confirmation page that data has been saved.
<cfif isDefined("Form.fileToUpload") and Form.fileToUpload
neq "">
<cfset uploadPath =
GetDirectoryFromPath(GetBaseTemplatePath()) & "uploads\">
<cfif not DirectoryExists(uploadPath)>
<cfdirectory action="create" directory="#uploadPath#">
</cfif>
<cffile action="upload" fileField="fileToUpload"
destination="#uploadPath#" nameConflict="overwrite">
<cfset imagefile= "uploads\\" & cffile.serverFile
& "'">
</cfif>
<cfquery name="qInsertPerson" dataSource="HRP">
Execute insertPerson
N'#Trim(FORM.sLastname)#',N'#Trim(FORM.sFirstname)#',N'#Trim(FORM.sMiddle)#',N'#Trim(FORM .sAlias)#',
'#imagefile#'
</cfquery>
<cflocation url = "savePersonResult.cfm" addToken =
"No">
#3.) This confirmation page displays last user entered and a
picture of the user. The user info retrieved from SQL server is
displaying correctly but the picture is not displaying(just a small
red 'x' box). The image calls another getPersonPhoto.cfm file to
display image.
<cfquery name="lastPerson" datasource="HRP">
Exec getLastRow
</cfquery>
<cfoutput query="lastPerson">
#firstName# #middle# #lastName# was added to our Persons
list. That Person has been given id: #id# <br>
Thank you for your assistance and cooperation.
<img src="getPersonPhoto.cfm?id=71" border="0" width="128"
height="180">
</cfoutput>
#4.) This is .cfm file that only displays image of person
<cfsetting enablecfoutputonly="Yes">
<cfsetting showdebugoutput="No">
<cfquery name="getBlob" datasource="HRP">
SELECT TOP 1 photo FROM Persons WHERE id = 71
</cfquery>
<cfheader name="content-disposition"
value="Inline;filename=ExamplePerson.jpg">
<cfcontent type="image/jpeg; charset=iso-8859-1">
<cfoutput>#tostring(tobinary(getBlob.photo))#</cfoutput>
Note: In my ColdFusion admin, I checked "Enable ... BLOB's"
and set Blob Buffer to 20000Regarding doing the actual saving, here are some other things
to consider:
* a max on the image's file size
* check if it really is an image
* don't use nameconflict="overwrite". consider
nameconflict="MAKEUNIQUE"
* delete uploaded image on file system after insert into db
Also, on the cfm page that returns an image, try putting the
cfcontent tag and the cfoutput tag on one line.
<cfheader name="Content-Type" value="image/jpeg">
<cfcontent
type="image/jpeg"><cfoutput>#getBlob.photo#</cfoutput>
Good luck! -
How to store 999999999.00000000 in sql server through ssis package?
I have a field with 999999999.00000000 value of datatype double ?
How to store it in ms sql server 2005 db through ssis package ?
give me details if I have to use derived columns and what to write over there.
please write in details as I am new to SSIS.
Thanks in Advance.The value is coming from informix db .
Can u please suggest hw to write it in my package :
I have taken a OLE DB Source and wrote the follwing command :
" select CASE WHEN T1.t_maxs IS NULL THEN 0.00 ELSE T1.t_maxs END as max_inv
from ttiitm001010 T1 ".
Please give details, as i am new ... -
SQL Server Long Text column to Oracle CLOB via DB Link
Does anyone know how to load a SQL Server Long Text column into an Oracle CLOB column using DB Link? When I try to Select from SQL Server table into Oracle table, I receive the error "ORA-00997: illegal use of LONG datatype".
Thanks,
SusanHi,
This is a known restriction involving long columns -
(1) LONG datatype not supported with use of DBLINK when insert or update involves a select statement
(2) LONG datatype cannot be used in a WHERE clause, in INSERT into ... SELECT ... FROM
constructs, and in snapshots.
The workround is to use a PL/SQL procedure or try the SQLPLUS COPY command.
If you have access to My Oracle Support then review these notes -
Cannot Move A Long From non Oracle database Ora-00997: Illegal Use Of Long Datatype (Doc ID 1246594.1)
How To Workaround Error: Ora-00997: Illegal Use Of Long Datatype (Doc ID 361716.1)
Regards,
Mike -
Cross database join Oracle - SQL server date column - nQSError: 46008
Hi,
I am using OBIEE 10.1.3.4.2 and
I am able to make cross database join between Oracle and SQL server using varchar columns, but I am getting this error:
nQSError:22024-A comparison is being carried out between noncompatible type when I try to make "foreign key" join between two tables (one from Oracle, second from SQL Server) using number columns (INT, DOUBLE...). It is strange, but I when I make "complex join" on physical layer no error is thrown and everything works fine.
But I am not able to make join between tables using Date column. Column in Oracle table has DATE datatype, column in SQL server tables has datetimeoffset(7) datatype (example: 2011-07-19 13:14:22.2032605 +02:00). So I tried to cast datetimeoffset(7) to date datatype using "convert(DATE,HappenedOn,120)" - this returns me 2011-07-19 . In this format, BI can show converted date column, I can make filter using this date column, but I am not able to make physical join with Oracle table using this column
Answer using data from both joined tables gives me this error:
[nQSError: 46008] Internal error: File .\DataType\SUKeyCompare.cpp, line 875. (HY000)
Do you have some tips, how to solve this "bug"?Parse the command column to get the SSIS package file name may be your only option here.
-
Get local sql server data in sharepoint online
Hi
Can anyone tell, how to get local sql server data in SharePoint online.Hi Partha,
Are you taking about local content db to SharePoint Online, if yes then there is not direct way to restore your local content db to online instead if you have small data then you can save your site as a template including content and the upload that template
and create site on online using that template.
Below mentioned link might also help:
http://www.dos2web.com/Cloud/index.php/introducing-sharepoint-in-the-cloud/migrating-from-on-premises-to-sharepoint-online
If want to display data from any SQL database into your online site, please follow the below link
http://community.office365.com/en-us/f/148/t/178875.aspx
https://nhutcmos.wordpress.com/tag/show-sql-data-to-sharepoint/
Best Regards,
Brij K -
SharePoint Foundation 2010 supported sql server version?
Hi,
I am using SharePoint 2010 Foundation. I want to know what are all the SQL Server versions would support in SharePoint 2010 Foundation.
Could anyone tell me as soon as possible.
Thanks & Regards
Poomani SankaranIt requires Windows Server 2008 SP2 or Windows Server 2008 R2. It will not run on a Server Core installation.
It requires one of these versions of x64 SQL Server:
SQL Server 2005 SP3 CU3 (Build 4220) or greater (Note: SQL Server 2005 goes out of mainstream support in April 2011)
SQL Server 2008 SP1 CU2 (Build 2714) or greater
SQL Server 2008 R2
Check this blog
http://www.sqlservercentral.com/blogs/glennberry/2010/03/11/sharepoint-2010-and-various-versions-of-sql-server/
further from msdn
In order to maintain SharePoint and SQL Server compatibility we use the “SharePoint N-1
on SQL Server N+1” equation to determine version support. Using SharePoint Foundation 2010 as an example, the N release of SQL Server is 2008/2008 R2 and N+1 is SQL Server 2012. For Microsoft SharePoint Server 2013 the N release of SQL Server
is 2012 and the N+1 is SQL Server 2014.
https://technet.microsoft.com/en-us/library/cc288751(v=office.14).aspx -
INSERTING DATA INTO A SQL SERVER 2005 TABLE, WHICH HAS A IDENTITY COLUMN
Hi All,
I have to insert the data into a SQL SERVER 2005 Database table.
I am able to insert the data into a normal SQL Server table.
When I am trying to insert the data into a SQL Server table, which has a identity column (i.e. auto increment column in Oracle) I am getting error saying that can't insert value explicitly when IDENTITY_INSERT is set to OFF.
Had anybody tried this??
There are some SRs on this issue, Oracle agreed that it is a bug. I am wondering if there is any workaround from any one of you (refer Insert in MS-SQL database table with IDENTITY COLUMN
Thanks
V KumarEven I had raised a SR on this in October 2008. But didn't get any solution for a long time, finally I had removed the identity column from the table. I can't to that now :).
I am using 10.1.3.3.0 and MS SQL SERVER 2005, They said it is working for MS SQL SERVER TABLE, if the identity column is not a primary key and asked me to refer to note 744735.1.
I had followed that note, but still it is not working for me.
But my requirement is it should work for a MS SQL SERVER 2005 table, which has identity column as primary key.
Thanks
V Kumar -
How to create a database in Sql server management studio
how to create a database in Sql server management studio
One method is to run the SQL statement below from a SSMS query window:
CREATE DATABASE MyDatabase;
You can also right-click on the Databases node in SSMS Object explorer and select New Database.
Dan Guzman, SQL Server MVP, http://www.dbdelta.com -
I can't seem to find any clear answers to the implications of installing SQL Server 2012 standard edition vs. enterprise in regards to SharePoint 2013.
I understand that to get many of the features you need Enterprise edition of SQL 2012; but, what I can't figure out is if the backend SharePoint SQL 2012 is standard; but, the PowerPivot/SSRS server is Enterprise will we still get the features?
If we have 3 tier SharePoint farm, one of those tiers is for the SQL Server database backend. If that SQL instance is 2012 standard and we add another server to the farm w/ SQL 2012 Enterprise to handle the tabular models, PowerPivot, and SSRS in integrated
mode will we still get the features?
Or, can we (should we) install Enterprise 2012 as the SharePoint database backend and let that instance triple down as also the PowerPivot and SSRS instance?
The Degenerate DimensionHi MMilligan,
SQL Server 2012 Standard is not supported PowePivot for SharePoint . In addition, SQL Server 2012 Standard is also not support some Reporting Services Features.
For more information, please refer to Features Supported by the Editions of SQL Server 2012:
http://msdn.microsoft.com/en-us/library/cc645993.aspx.
Install SQL Server BI Features with SharePoint 2013 (SQL Server 2012 SP1):
http://msdn.microsoft.com/en-us/library/jj218795.aspx.
If you have any problem, please feel free to let me know.
Thanks.
If you have any feedback on our support, please click
here.
Maggie Luo
TechNet Community Support
Maybe you are looking for
-
New analysis XML customizedcriteria 11.1.1.5.0
Hi, I create an analysis and I change subject area in XML with a presentation variable. So I have one report for different subject areas (Subject area's have same dimensions but different members, so my report works fine). Depending prompt it shows e
-
Dear Friend, Can anybody tell me whether it is possible to park Invoiceverification document in MIRO by MM department and posting can be done by FI department. Thanks Uma
-
Hi all, I created a custom infotype in PA. Its working fine in development client. But in all other clients it gives a error message 'entry doesn't exist in V_T582A table'. I think this is because of infotype characteristics are client dependent.But
-
Error showing data in web bexmaps
Hi everyone, im using bexmaps, when i use it in excell everything is ok, but in web aplication the maps (that is divided in regions) show me data in all region less in one (but it should show it because it as data), did someone already get this error
-
How to restore contacts on a 4s?
hi i'm a new baby here how can i copy my present contact from pc (in format vCard file) to iphone 4s? my old sim is not micro sim so cannot copy (not support) from prev phone to sim