{"title":"Ingest your first data","description":"Append a small record to an Altertable table with the CLI, query it to verify ingestion, and continue with file uploads or an agent-led setup.","order":100,"askSuggestions":["Why doesn't my appended record show up in queries?","How do I upload a CSV or Parquet file?","How do I update existing rows instead of appending?"],"navigation":true,"routeId":"gettingStartedIngestData","body":{"code":"var Component=(()=>{var m=Object.create;var s=Object.defineProperty;var b=Object.getOwnPropertyDescriptor;var f=Object.getOwnPropertyNames;var w=Object.getPrototypeOf,y=Object.prototype.hasOwnProperty;var x=(n,e)=>()=>(e||n((e={exports:{}}).exports,e),e.exports),v=(n,e)=>{for(var a in e)s(n,a,{get:e[a],enumerable:!0})},l=(n,e,a,r)=>{if(e&&typeof e==\"object\"||typeof e==\"function\")for(let o of f(e))!y.call(n,o)&&o!==a&&s(n,o,{get:()=>e[o],enumerable:!(r=b(e,o))||r.enumerable});return n};var D=(n,e,a)=>(a=n!=null?m(w(n)):{},l(e||!n||!n.__esModule?s(a,\"default\",{value:n,enumerable:!0}):a,n)),I=n=>l(s({},\"__esModule\",{value:!0}),n);var u=x((q,h)=>{h.exports=_jsx_runtime});var P={};v(P,{default:()=>g,frontmatter:()=>k});var t=D(u()),k={title:\"Ingest your first data\",routeId:\"gettingStartedIngestData\",description:\"Append a small record to an Altertable table with the CLI, query it to verify ingestion, and continue with file uploads or an agent-led setup.\",order:100,askSuggestions:[\"Why doesn't my appended record show up in queries?\",\"How do I upload a CSV or Parquet file?\",\"How do I update existing rows instead of appending?\"]};function p(n){let e={a:\"a\",code:\"code\",h1:\"h1\",h2:\"h2\",p:\"p\",pre:\"pre\",...n.components},{DocsCliPrerequisite:a,DocsPreviewDocument:r,DocsPreviewSection:o,DocsPrompt:d,DocsPrompts:c}=e;return a||i(\"DocsCliPrerequisite\",!0),r||i(\"DocsPreviewDocument\",!0),o||i(\"DocsPreviewSection\",!0),d||i(\"DocsPrompt\",!0),c||i(\"DocsPrompts\",!0),(0,t.jsxs)(r,{anchors:\"ingest-your-first-data 1-choose-a-destination 2-append-a-record 3-read-it-back do-this-with-your-agent\",children:[(0,t.jsxs)(o,{sectionId:\"ingest-your-first-data\",sectionTitle:\"Ingest your first data\",anchors:\"\",ancestors:\"\",index:\"0\",children:[(0,t.jsx)(e.h1,{id:\"ingest-your-first-data\",children:\"Ingest your first data\"}),`\n`,(0,t.jsx)(e.p,{children:\"Create a writable catalog, append one record, and read it back.\"}),`\n`,(0,t.jsxs)(e.p,{children:[\"A new environment already has lakehouse credentials, a managed storage bucket, and a read-only Altertable system catalog. The initial \",(0,t.jsx)(e.code,{children:\"sandbox\"}),\" environment also has read-only Sample Data. You do not need to provision credentials or storage for this quickstart; you do need a writable catalog for your own data.\"]}),`\n`,(0,t.jsx)(a,{defaultOpen:!0}),`\n`]}),(0,t.jsxs)(o,{sectionId:\"1-choose-a-destination\",sectionTitle:\"1. Choose a destination\",anchors:\"\",ancestors:\"\",index:\"1\",children:[(0,t.jsx)(e.h2,{id:\"1-choose-a-destination\",children:\"1. Choose a destination\"}),`\n`,(0,t.jsx)(e.p,{children:\"After login, confirm the environment and create a writable catalog:\"}),`\n`,(0,t.jsx)(e.pre,{children:(0,t.jsx)(e.code,{className:\"language-altertable\",children:`altertable profile show\naltertable catalog create onboarding\n`})}),`\n`,(0,t.jsxs)(e.p,{children:[\"Use \",(0,t.jsx)(e.code,{children:\"onboarding\"}),\" in the commands below. If that name already exists, run \",(0,t.jsx)(e.code,{children:\"altertable catalog\"}),\" and choose a writable catalog you own, or create one with a different name. Replace \",(0,t.jsx)(e.code,{children:\"onboarding\"}),\" consistently in both commands.\"]}),`\n`]}),(0,t.jsxs)(o,{sectionId:\"2-append-a-record\",sectionTitle:\"2. Append a record\",anchors:\"\",ancestors:\"\",index:\"2\",children:[(0,t.jsx)(e.h2,{id:\"2-append-a-record\",children:\"2. Append a record\"}),`\n`,(0,t.jsx)(e.pre,{children:(0,t.jsx)(e.code,{className:\"language-altertable\",children:`altertable append '{\"event\":\"onboarding_test\",\"source\":\"quickstart\"}' --to onboarding.main.onboarding_events\n`})}),`\n`,(0,t.jsx)(e.p,{children:\"Append creates a missing table and infers its columns. Processing is asynchronous, so allow a few seconds before querying.\"}),`\n`]}),(0,t.jsxs)(o,{sectionId:\"3-read-it-back\",sectionTitle:\"3. Read it back\",anchors:\"\",ancestors:\"\",index:\"3\",children:[(0,t.jsx)(e.h2,{id:\"3-read-it-back\",children:\"3. Read it back\"}),`\n`,(0,t.jsx)(e.pre,{children:(0,t.jsx)(e.code,{className:\"language-altertable\",children:`altertable query \"SELECT event, source FROM onboarding.main.onboarding_events WHERE event = 'onboarding_test' LIMIT 10\"\n`})}),`\n`,(0,t.jsxs)(e.p,{children:[\"Confirm that the result contains \",(0,t.jsx)(e.code,{children:\"onboarding_test\"}),\" and \",(0,t.jsx)(e.code,{children:\"quickstart\"}),\". If the record is missing, inspect the append result and \",(0,t.jsx)(e.a,{href:\"/docs/lakehouse/ingest/http-api#troubleshooting\",children:\"ingestion troubleshooting\"}),\".\"]}),`\n`]}),(0,t.jsxs)(o,{sectionId:\"do-this-with-your-agent\",sectionTitle:\"Do this with your agent\",anchors:\"\",ancestors:\"\",index:\"4\",children:[(0,t.jsx)(e.h2,{id:\"do-this-with-your-agent\",children:\"Do this with your agent\"}),`\n`,(0,t.jsx)(c,{children:(0,t.jsx)(d,{children:\"Read https://altertable.ai/docs/getting-started/ingest-data.md. Help me load a small first dataset into Altertable. Inspect available catalogs and ask only which source data or target environment you cannot determine. Show the exact destination and write operation for review before writing; do not overwrite existing data. Verify a known record with a bounded query, compare its fields with the source, and report the rows loaded and any rejected records. Diagnose an empty result rather than treating it as success.\"})}),`\n`,(0,t.jsxs)(e.p,{children:[\"Next, \",(0,t.jsx)(e.a,{href:\"/docs/lakehouse/ingest/http-api\",children:\"load your own records or files\"}),\".\"]})]})]})}function g(n={}){let{wrapper:e}=n.components||{};return e?(0,t.jsx)(e,{...n,children:(0,t.jsx)(p,{...n})}):p(n)}function i(n,e){throw new Error(\"Expected \"+(e?\"component\":\"object\")+\" `\"+n+\"` to be defined: you likely forgot to import, pass, or provide it.\")}return I(P);})();\n;return Component;"},"_id":"docs/getting-started/ingest-data.mdx","_raw":{"sourceFilePath":"docs/getting-started/ingest-data.mdx","sourceFileName":"ingest-data.mdx","sourceFileDir":"docs/getting-started","contentType":"mdx","flattenedPath":"docs/getting-started/ingest-data"},"type":"Docs","path":"/getting-started/ingest-data","level":2,"parent":"getting-started"}